const { defineConfig } = require('@vue/cli-service');

module.exports = defineConfig({
  transpileDependencies: true,
  devServer: {
    port: 9004,
    proxy: {
      '/api': {
        target: 'http://localhost:8004', // 服务器地址
        changeOrigin: true,
        pathRewrite: { '^/api': '' } // 重写路径，去掉 /api 前缀
      }
    }
  }
});